package www.lagou.entity;

import java.util.Objects;

/**
 * dept 表对应的 JavaBean 类。
 */
public class Dept {
    private int id;
    private String deptname;

    public Dept() {
    }

    public int getId() {
        return id;
    }

    public void setId(int id) {
        this.id = id;
    }

    public String getDeptname() {
        return deptname;
    }

    public void setDeptname(String deptname) {
        this.deptname = deptname;
    }

    @Override
    public boolean equals(Object o) {
        if (this == o) return true;
        if (o == null || getClass() != o.getClass()) return false;
        Dept dept = (Dept) o;
        return id == dept.id &&
                Objects.equals(deptname, dept.deptname);
    }

    @Override
    public int hashCode() {
        return Objects.hash(id, deptname);
    }

    @Override
    public String toString() {
        return "Dept{" +
                "id=" + id +
                ", deptname='" + deptname + '\'' +
                '}';
    }
}
